package cn.videoview;

import android.app.Activity;
import android.os.Bundle;
import android.widget.MediaController;
import android.widget.VideoView;

public class FirstActivity extends Activity {
    private VideoView videoView;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_first);

        videoView = findViewById(R.id.my_videoView);

        videoView.setVideoPath("/mnt/shared/Other/family.mp4");
        videoView.start();

        MediaController mediaController = new MediaController(FirstActivity.this);
        videoView.setMediaController(mediaController);
    }
}